// 透明表单
$transparent-height: .5rem;
$transparent-color: $primary--color-0-1;
$transparent-color-error: #FF5722;
$transparent-color-focus: #E0E0E0;
$transparent-color-tip: #FFA25B;


.transparent-form{
    width: 100%;
    .el-form-item.el-form-item--medium{
        margin-bottom: 0;
    }
    .el-button.el-button--medium{
        border-radius: .15rem;
        height: $transparent-height;
        font-size: .18rem;
        background-color: rgba(51, 157, 255, 1);
        border-color: rgba(51, 157, 255, 1);
    }
    .cf__group{
        position: relative;
        .cf__group-info{
            width: 100%;
            &.flex{
                @include flexLayout(flex,normal,center);
            }
            &.flex-end{
                @include flexLayout(flex,right,center);
            }
        }
        .cf__group-tips{
            z-index: 2;
            line-height: 1.4;
            font-size: .14rem;
            word-break: break-all;
            color: $transparent-color-tip;
            transition: color .3s linear;
            padding: .1rem .1rem 0;
        }
        .el-input--medium .el-input__inner{
            color: $transparent-color-focus;
            line-height: $transparent-height;
            height: $transparent-height;
            background-color: transparent;
            border-radius: .15rem;
            padding-left: .7rem;
            @include inputPlaceholder($transparent-color);
        }

        .el-input--medium .el-input__inner:focus{
            color: $transparent-color-focus;
        }
        &.error{
            .cf__group-tips{
                color: $transparent-color-error;
            }
            .el-input__inner{
                border-color: $transparent-color-error;
            }
        }
    }
}


// 自定义表单
$custom-height: .4rem;
$custom-color: $primary--color-0-1;
$custom-color-error: #FF5722;
$custom-color-focus: $primary--color-3;
.custom-form{
    width: 100%;
    padding: 0 .3rem;
    .el-form-item.el-form-item--medium{
        margin-bottom: 0;
        &.position-left{
            @include flexLayout(flex,normal,normal);
            .el-form-item__label{
                flex: 0 0 auto;
            }
            .el-form-item__content{
                padding-left: .1rem;
                flex: 1;
                width: 100%;
            }
        }
    }
    .el-form-item--medium .el-form-item__label{
        line-height: $custom-height;
    }
    .cf__group{
        padding-bottom: 30px;
        position: relative;
        .cf__group-info{
            width: 100%;
            &.flex{
                @include flexLayout(flex,normal,center);
            }
        }
        .cf__group-tips{
            position: absolute;
            font-size: 12px;
            bottom: 0;
            left: 0;
            z-index: 2;
            height: 30px;
            transform-origin: 0 50%;
            transform: scale(1);
            color: $custom-color-focus;
            transition: color .3s linear;
            line-height: 30px;
        }
        .el-textarea.el-input--medium,
        .el-date-editor.el-input,
        .el-textarea.el-input--medium .el-textarea__inner,
        .el-input--medium .el-input__inner{
            color: $custom-color-focus;
            background-color: transparent;
            width: 4rem;
            font-size: .14rem;
            @include inputPlaceholder($custom-color);
        }
        .el-textarea.el-input--medium .el-textarea__inner{
            padding-bottom: .36rem;
        }
        .el-textarea.el-input--medium .el-input__count{
            bottom: .01rem;
            padding: 0 .1rem;
        }
        .el-input__count
        .el-button{
            padding-top: .12rem;
            padding-bottom: .12rem;
        }
        .el-switch{
            padding-top: .02rem;
        }
        .el-input--medium .el-input__inner{
            height: $custom-height;
            line-height: $custom-height;
            @include inputPlaceholder($custom-color);
        }

        .el-input--medium .el-input__inner:focus{
            color: $custom-color-focus;
        }
        .el-range-editor--medium.el-input__inner{
            height: $custom-height;
            .el-range-separator{
                width: 10%;
            }
        }

        &.error{
            .cf__group-tips{
                color: $custom-color-error;
            }
            .el-input__inner{
                border-color: $custom-color-error;
            }
        }
    }
}




.page-transition-slide-in-right-enter-active {
    animation: page-transition-slide-in-right-enter $default-transition-duration both $default-transition-timing;
}
@keyframes page-transition-slide-in-right-enter {
    0% {
        transform: translateX(20px);
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

/* 离开过渡的状态 */
.page-transition-slide-in-right-leave-active {
    animation: page-transition-slide-in-right-leave $default-transition-duration both $default-transition-timing;
}
@keyframes page-transition-slide-in-right-leave {
    0% {
        opacity: 1;
    }

    100% {
        transform: translateX(-20px);
        opacity: 0;
    }
}
.page-transition-slide-in-top-enter-active {
    animation: page-transition-slide-in-top-enter $default-transition-duration both $default-transition-timing;
}
@keyframes page-transition-slide-in-top-enter {
    0% {
        transform: translateY(-20px);
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

/* 离开过渡的状态 */
.page-transition-slide-in-top-leave-active {
    animation: page-transition-slide-in-top-leave $default-transition-duration both $default-transition-timing;
}
@keyframes page-transition-slide-in-top-leave {
    0% {
        opacity: 1;
    }

    100% {
        transform: translateY(-20px);
        opacity: 0;
    }
}